﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using SmallERP.MODEL.FoundationModel;

namespace SmallERP.MODEL.PrintManage
{
    public class BoardModel:Board_Info
    {
        public string StatusName
        {
            get
            {
                switch (base.Status)
                {
                    case 0:
                        return "未打印";

                    case 1:
                        return "正在打印";

                    case 2:
                        return "打印完成";

                    case 3:
                        return "等待生成大图";

                    case 4:
                        return "正在生成大图";

                    case 5:
                        return "生成大图错误";

                    case 6:
                        return "暂停";

                    case 7:
                        return "没有找到大图";

                    case 8:
                        return "等待加密";

                    default:
                        return "未定义";



                };
            }
        }

        public string PaperFaceName { get; set; }
        public string PaperTypeName { get; set; }
        public double BoardArea { get; set; }
        public double LengthView { get; set; }
        public double widthView { get; set; }

        public string SizeInch { get {
            return base.Height + "x" + base.Length;
        } }
        public string SizeCm
        {
            get
            {
                return (base.Height * 2.54 / base.DPI).ToString("0.00") + "x" + (base.Length * 2.54 / base.DPI).ToString("0.00");
            }
        }
        public string UsePersent { get { return ((1 - base.WasteRate) * 100).ToString("0.00")+"%"; } }
        public string Areas { get { return (base.Height * 2.54 * base.Length * 2.54 / 10000 / base.DPI / base.DPI).ToString("0.0000"); } }
        public string Remark { get; set; }//错误信息
        public double BoardLength { get { return base.Length * 2.54 / base.DPI; } }
        public string Delete = "退版";//错误信息
        public string ReProduct = "重新生成";//错误信息
    }
}
